<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@page import="org.jeecgframework.web.util.StaticValue" %>
<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@include file="/context/mytags.jsp" %>
<!DOCTYPE html>
<html>
<head>
    <title>取消发货</title>
    <t:base type="jquery,easyui,tools,DatePicker"></t:base>
    <script type="text/javascript" src="plug-in/ckfinder/ckfinder.js"></script>
    <link rel="stylesheet" href="plug-in/uploadify/css/uploadify.css" type="text/css"/>
    <script type="text/javascript" src="plug-in/uploadify/jquery.uploadify-3.1.min.js"></script>
    <script type="text/javascript" src="plug-in/jquery/ajaxfileupload.js"></script>
    <script type="text/javascript" src="plug-in/jquery/jquerysession.js"></script>
</head>
<body>
<div id="dialog">
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table"
             action="cbsDelinerController.do?removeDeliver" tiptype="1">
    <br>
    <label>请填写取消发货的原因：</label>
    <br>
    <input type="text" name="id" id="id" value="${id}" hidden><br>
    <input type="text" name="code" id="code" value="${code}" hidden><br>
    <textarea id="candelDes" name="candelDes" style="margin-left: 20px; height: 150px; width: 450px;" datatype="*1-255" maxlength="255" nullMsg="请填写取消发货的原因"> </textarea>
    <span class="Validform_checktip"></span>
    <label class="Validform_label" style="display: none;">取消原因</label>
</t:formvalid>
</div>
</body>
<script>
    var form = $("#formobj").Validform({
        ignoreHidden: true,
        postonce: true,
        showAllError: true,
        ajaxPost: true,
        tiptype: 3,
        beforeSubmit: function () {
            submit();
        }
    });

    $("#submitBtn1").click(function () {
        submit();
    });

    function submit() {
        var tabName='编辑'+$('#code').val()
        //调用formValidata 进行验证，并能阻止提交
        if (!form.check(false)) {
            form.submitForm(false);
            return false;
        }else{
            setTimeout("addOneTab('发货管理','cbsDelinerController.do?cbsDeliner');", 1000);
            setTimeout("closetab('" + tabName + "')", 1000);
        }

    }

</script>
</html>
